#ifndef QLUA_H
#define QLUA_H

#include <QObject>
#include <QCoreApplication>
#include <QFile>

//导入lua标准库
extern "C" {
#include "lua.h"
#include "lauxlib.h"
#include "lualib.h"
}

class QLua: public QObject
{
    Q_OBJECT
public:
    QLua();
    ~QLua();

private:
    lua_State* L;
    QString m_ScriptFileName = "../luaScripts/command.lua";

public:
    QString GetCommand(QString p, QString w, QString n);
    QString GetCmd(QStringList list);
    QString ScriptFileName() const;
    void setScriptFileName(const QString &ScriptFileName);
};

#endif // QLUA_H
